package com.serena.da.rest.http_helpers;

import org.apache.http.client.methods.HttpPut;
import org.apache.http.entity.StringEntity;


/**
 * Created by Spitkovskyi Igor on 7/30/2014.
 */
public class PutRequest extends HttpPut {
    public PutRequest(String url) {
        super(url);
    }

    //Putting payload entity into request
    public void setEntity(String json) throws java.io.UnsupportedEncodingException {
        StringEntity payload = new StringEntity(json);
        payload.setContentType("application/json");
        setEntity(payload);
    }
}
